home *** CD-ROM | disk | FTP | other *** search
/ Chip 2007 January, February, March & April / Chip-Cover-CD-2007-02.iso / Pakiet bezpieczenstwa / mini Pentoo LiveCD 2006.1 / mpentoo-2006.1.iso / livecd.squashfs / usr / lib / mozilla-firefox / include / necko / nsICookie2.h < prev    next >
C/C++ Source or Header  |  2006-05-08  |  4KB  |  135 lines

  1. /*
  2.  * DO NOT EDIT.  THIS FILE IS GENERATED FROM nsICookie2.idl
  3.  */
  4.  
  5. #ifndef __gen_nsICookie2_h__
  6. #define __gen_nsICookie2_h__
  7.  
  8.  
  9. #ifndef __gen_nsICookie_h__
  10. #include "nsICookie.h"
  11. #endif
  12.  
  13. /* For IDL files that don't want to include root IDL files. */
  14. #ifndef NS_NO_VTABLE
  15. #define NS_NO_VTABLE
  16. #endif
  17.  
  18. /* starting interface:    nsICookie2 */
  19. #define NS_ICOOKIE2_IID_STR "d3493503-7854-46ed-8284-8af54a847efb"
  20.  
  21. #define NS_ICOOKIE2_IID \
  22.   {0xd3493503, 0x7854, 0x46ed, \
  23.     { 0x82, 0x84, 0x8a, 0xf5, 0x4a, 0x84, 0x7e, 0xfb }}
  24.  
  25. /** 
  26.  * Main cookie object interface for use by consumers:
  27.  * extends nsICookie, a frozen interface for external
  28.  * access of cookie objects
  29.  */
  30. class NS_NO_VTABLE nsICookie2 : public nsICookie {
  31.  public: 
  32.  
  33.   NS_DEFINE_STATIC_IID_ACCESSOR(NS_ICOOKIE2_IID)
  34.  
  35.   /**
  36.      * the host (possibly fully qualified) of the cookie,
  37.      * without a leading dot to represent if it is a
  38.      * domain cookie.
  39.      */
  40.   /* readonly attribute AUTF8String rawHost; */
  41.   NS_IMETHOD GetRawHost(nsACString & aRawHost) = 0;
  42.  
  43.   /**
  44.      * true if the cookie is a session cookie
  45.      * (note: if true, the expiry time is undefined).
  46.      */
  47.   /* readonly attribute boolean isSession; */
  48.   NS_IMETHOD GetIsSession(PRBool *aIsSession) = 0;
  49.  
  50.   /**
  51.      * the actual expiry time of the cookie
  52.      * (where 0 does not represent a session cookie).
  53.      *
  54.      * not to be confused with |expires|, an
  55.      * attribute on nsICookie.
  56.      */
  57.   /* readonly attribute PRInt64 expiry; */
  58.   NS_IMETHOD GetExpiry(PRInt64 *aExpiry) = 0;
  59.  
  60. };
  61.  
  62. /* Use this macro when declaring classes that implement this interface. */
  63. #define NS_DECL_NSICOOKIE2 \
  64.   NS_IMETHOD GetRawHost(nsACString & aRawHost); \
  65.   NS_IMETHOD GetIsSession(PRBool *aIsSession); \
  66.   NS_IMETHOD GetExpiry(PRInt64 *aExpiry); 
  67.  
  68. /* Use this macro to declare functions that forward the behavior of this interface to another object. */
  69. #define NS_FORWARD_NSICOOKIE2(_to) \
  70.   NS_IMETHOD GetRawHost(nsACString & aRawHost) { return _to GetRawHost(aRawHost); } \
  71.   NS_IMETHOD GetIsSession(PRBool *aIsSession) { return _to GetIsSession(aIsSession); } \
  72.   NS_IMETHOD GetExpiry(PRInt64 *aExpiry) { return _to GetExpiry(aExpiry); } 
  73.  
  74. /* Use this macro to declare functions that forward the behavior of this interface to another object in a safe way. */
  75. #define NS_FORWARD_SAFE_NSICOOKIE2(_to) \
  76.   NS_IMETHOD GetRawHost(nsACString & aRawHost) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetRawHost(aRawHost); } \
  77.   NS_IMETHOD GetIsSession(PRBool *aIsSession) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetIsSession(aIsSession); } \
  78.   NS_IMETHOD GetExpiry(PRInt64 *aExpiry) { return !_to ? NS_ERROR_NULL_POINTER : _to->GetExpiry(aExpiry); } 
  79.  
  80. #if 0
  81. /* Use the code below as a template for the implementation class for this interface. */
  82.  
  83. /* Header file */
  84. class nsCookie2 : public nsICookie2
  85. {
  86. public:
  87.   NS_DECL_ISUPPORTS
  88.   NS_DECL_NSICOOKIE2
  89.  
  90.   nsCookie2();
  91.  
  92. private:
  93.   ~nsCookie2();
  94.  
  95. protected:
  96.   /* additional members */
  97. };
  98.  
  99. /* Implementation file */
  100. NS_IMPL_ISUPPORTS1(nsCookie2, nsICookie2)
  101.  
  102. nsCookie2::nsCookie2()
  103. {
  104.   /* member initializers and constructor code */
  105. }
  106.  
  107. nsCookie2::~nsCookie2()
  108. {
  109.   /* destructor code */
  110. }
  111.  
  112. /* readonly attribute AUTF8String rawHost; */
  113. NS_IMETHODIMP nsCookie2::GetRawHost(nsACString & aRawHost)
  114. {
  115.     return NS_ERROR_NOT_IMPLEMENTED;
  116. }
  117.  
  118. /* readonly attribute boolean isSession; */
  119. NS_IMETHODIMP nsCookie2::GetIsSession(PRBool *aIsSession)
  120. {
  121.     return NS_ERROR_NOT_IMPLEMENTED;
  122. }
  123.  
  124. /* readonly attribute PRInt64 expiry; */
  125. NS_IMETHODIMP nsCookie2::GetExpiry(PRInt64 *aExpiry)
  126. {
  127.     return NS_ERROR_NOT_IMPLEMENTED;
  128. }
  129.  
  130. /* End of implementation class template. */
  131. #endif
  132.  
  133.  
  134. #endif /* __gen_nsICookie2_h__ */
  135.